import { defineStore } from 'pinia'
import { computed, ref } from 'vue'
export const useXxx = defineStore('xxx', () => {
  const state = ref({ name: 'zs' })
  const aaa = ref(999)
  const getName = computed(() => {
    return '姓名:' + state.value.name
  })
  const setState = (val: { name: string }) => {
    state.value = val
  }
  return { state, getName, setState, aaa }
})
